﻿@model DeJC.DAL.Model.Product

@{
    ViewBag.Title = "Create";
    Layout="~/Views/Shared/_LayoutConfig.cshtml";

    }

<h2>Create</h2>

<script src="@Url.Content("~/Scripts/jquery.validate.min.js")" type="text/javascript"></script>
<script src="@Url.Content("~/Scripts/jquery.validate.unobtrusive.min.js")" type="text/javascript"></script>

@using (Html.BeginForm()) {
    @Html.ValidationSummary(true)
    <fieldset>
        <legend>Product</legend>
        <div class="form-style">
            <ul>
                <li>
                    <div class="editor-label">
                        @Html.LabelFor(model => model.ProductBrandID, "Marca")
                    </div>
                    <div class="editor-field">
                        @Html.DropDownList("ProductBrandID", String.Empty)
                        @Html.ValidationMessageFor(model => model.ProductBrandID)
                    </div>
                </li>
                <li>
                    <div class="editor-label">
                        @Html.LabelFor(model => model.CategoryID, "Categoria")
                    </div>
                    <div class="editor-field">
                        @Html.DropDownList("CategoryID", String.Empty)
                        @Html.ValidationMessageFor(model => model.CategoryID)
                    </div>
                </li>
                <li>
                    <div class="editor-label">
                        @Html.LabelFor(model => model.UnitID, "Unidades")
                    </div>
                    <div class="editor-field">
                        @Html.DropDownList("UnitID", String.Empty)
                        @Html.ValidationMessageFor(model => model.UnitID)
                    </div>
                </li>
                <li>
                    <div class="editor-label">
                        @Html.LabelFor(model => model.Name,"Nombre")
                    </div>
                    <div class="editor-field">
                        @Html.EditorFor(model => model.Name)
                        @Html.ValidationMessageFor(model => model.Name)
                    </div>
                </li>
                <li>
                    <div class="editor-label">
                        @Html.LabelFor(model => model.Description,"Descripción")
                    </div>
                    <div class="editor-field">
                        @Html.EditorFor(model => model.Description)
                        @Html.ValidationMessageFor(model => model.Description)
                    </div>
                </li>
                <li>
                    <div class="editor-label">
                        @Html.LabelFor(model => model.Size,"Tamaño")
                    </div>
                    <div class="editor-field">
                        @Html.EditorFor(model => model.Size)
                        @Html.ValidationMessageFor(model => model.Size)
                    </div>
                </li>
                <li>
                    <div class="editor-label">
                        @Html.LabelFor(model => model.Price,"Precio")
                    </div>
                    <div class="editor-field">
                        @Html.EditorFor(model => model.Price)
                        @Html.ValidationMessageFor(model => model.Price)
                    </div>
                </li>
            </ul>
            <hr/>
        </div>
        <div class="form-style">
            <ul>
                <li>
                    <div class="editor-label">
            @Html.LabelFor(model => model.ImagePathSmall)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.ImagePathSmall)
            @Html.ValidationMessageFor(model => model.ImagePathSmall)
        </div>
                </li>
                <li>
                    <div class="editor-label">
            @Html.LabelFor(model => model.ImagePathMedium)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.ImagePathMedium)
            @Html.ValidationMessageFor(model => model.ImagePathMedium)
        </div>
                </li>
                <li>
                    <div class="editor-label">
            @Html.LabelFor(model => model.ImagePathLarge)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.ImagePathLarge)
            @Html.ValidationMessageFor(model => model.ImagePathLarge)
        </div>
                </li>                
            </ul>
            <hr/>
        </div>
@*
        <div class="editor-label">
            @Html.LabelFor(model => model.Deleted)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.Deleted)
            @Html.ValidationMessageFor(model => model.Deleted)
        </div>

        <div class="editor-label">
            @Html.LabelFor(model => model.DeletedDate)
        </div>
        <div class="editor-field">
            @Html.EditorFor(model => model.DeletedDate)
            @Html.ValidationMessageFor(model => model.DeletedDate)
        </div>
*@

        <p>
            <input type="submit" value="Create" />
            @Html.ActionLink("Back to List", "Index")
        </p>
    </fieldset>
}